﻿using System.Data;

namespace CNF.Common.Base.SimpleOrm.Data.DbColumns
{
    public class DbBoolColumn : BaseDbColumn
    {
        public DbBoolColumn(string name,string displayName, bool nullable)
            : base(name, 2, SqlDbType.Bit, displayName, nullable)
        {
        }

        public string BulidEq(bool value)
        {
            return string.Format(" ([{0}] = {1})s ", this.name, value ? "1" : "0");
        }
    }
}
